#ifndef __FIIP_STDP_H
#define __FIIP_STDP_H
#include <stdint.h>
#include <stdlib.h>
#include "./stdpFormat.h"
#include "fiip-base/fiip.h"
#include "fiip-base/link/link.h"
#include "riselib/mempool.h"

#ifdef __cplusplus
extern "C" {
#endif

#define STDP_LISTENERS_LEN_MAX 64

typedef struct {
  uint16_t cmd;
  void (*fun)(Stdp_FieldStruct* msg);
} Stdp_ListenerStruct;  //监听器结构体

void stdp_start(void);
void stdp_addListener(uint16_t cmd, void (*fun)(Stdp_FieldStruct* msg));

#ifdef __cplusplus
}
#endif
#endif  //__FIIP_STDP_H
